package com.zhny.aiot.solar.roll.film.plugin.model;

import com.zhny.aiot.plugin.ActionValue;
import com.zhny.aiot.plugin.PropertyValue;
import com.zhny.aiot.plugin.model.*;
import lombok.Data;

@Data
public class RollFilmStoreEntry extends StoreEntity {
    @PropertyValue(alias = "光伏卷膜器",description = "卷膜器状态",unit = "",icon=IconConstract.Other,variableType=VariableType.SolarRollFilm,actions={
            @ActionValue(name=Operate.Open,commandCode="open",eventType=EventType.Click),
            @ActionValue(name=Operate.Close,commandCode="close",eventType=EventType.Click),
            @ActionValue(name=Operate.Stop,commandCode="stop",eventType=EventType.Click),
            @ActionValue(name=Operate.Query,commandCode="query",eventType=EventType.Click),
            @ActionValue(name=Operate.Init,commandCode="initialize",eventType=EventType.Click)
    })
    private String rollFilmStatus;

    @PropertyValue(alias = "电压",description = "电池电压",unit = "V",icon=IconConstract.Voltage,variableType=VariableType.Numerical,actions={
            @ActionValue(name=Operate.Check, commandCode="queryVoltage", eventType=EventType.Click)
    })
    private Double voltage;

    @Override
    public String toString() {
        StringBuffer sb = new StringBuffer();
        sb.append("voltage=").append(this.voltage);
        sb.append(", rollFilmStatus=").append(this.rollFilmStatus);
        return sb.toString();
    }
}
